How to solve if else python in hackerrank

join shbcf.ru